﻿Public Class resumen_corte


#Region " Variables de trabajo "
    Dim Caja As String = ""
    Dim Parametros As String = ""
    Dim lConsulta As New ClsConsultas
    Dim ObjRet As CRetorno
#End Region

    
    Private Sub btnAceptar_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnAceptar.Click
        Me.Close()
    End Sub

    Private Sub resumen_corte_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        'Servicios
        Caja = "Consulta163" : Parametros = "V1=" & DateTime.Now.ToString("MM/dd/yyyy HH:mm:ss") & "|"
        If lConsulta Is Nothing Then lConsulta = New ClsConsultas
        ObjRet = lConsulta.LlamarCaja(Caja, "10", Parametros)
        'Estatus
        If ObjRet.bOk Then
            'Asignar
            Me.lblR_ventas.Text = lConsulta.ObtenerValor("V1", ObjRet.sResultado, "|")
            Me.lblR_otros.Text = lConsulta.ObtenerValor("V2", ObjRet.sResultado, "|")
            Me.lblRE_total.Text = lConsulta.ObtenerValor("V3", ObjRet.sResultado, "|")
            Me.lblRS_otros.Text = lConsulta.ObtenerValor("V4", ObjRet.sResultado, "|")
            Me.lblRS_total.Text = lConsulta.ObtenerValor("V5", ObjRet.sResultado, "|")
            Me.lblEfectivo.Text = lConsulta.ObtenerValor("V6", ObjRet.sResultado, "|")

        Else
            
            'mensaje
            MessageBox.Show(lConsulta.ObtenerValor("2M", ObjRet.sResultado, "|", False))
        
        End If
        'Destruir
        ObjRet = Nothing
    End Sub
End Class